#ifndef __LOADCFG_H
#define __LOADCFG_H

#define MOMAP_ISDIRTY 0x1
#define MOMAP_ISCLEAN 0x0
#define CONFIG_ISOK 0x0
#define CONFIG_ISERR_NODE 0x1
#define CONFIG_ISERR_ELEMENT 0x2

#define IS_STRING 0x1
#define IS_INTEGER 0x2
#define IS_FLOAT 0x3
#define IS_ADDR_IP 0x4
#define IS_ADDR_MAC 0x5
#define IS_ENABLE 0x6

typedef struct
{
	char *index;
	int len;
	char *addr;
	int flag;
	int id;
	int type;
}MOMAP_S, *MOMAP_PS;

typedef struct element_s
{
	char name[20];
	int flag;
	int count;
	MOMAP_PS pstMap;
	struct element_s *pnext;
}ELEMENT_S, *ELEMENT_PS;


int add_configure(ELEMENT_PS pstAdd);
int load_configure();
int save_configure(char *file_name);
int copy_cfg(HWND hDlg, MOMAP_PS pstMap, int cnt);
int format_print(char *buff, int length);
void print_info();





#endif
